package com.qf.test;

import com.qf.dao.FangDongService;
import com.qf.dao.Impl.FangDongProxyImpl;
import com.qf.dao.Impl.FangDongServiceImpl;
import org.junit.Test;

/**
 * @author mkr
 * @version V1.0
 * @Project spring_demo
 * @Package com.qf.test
 * @Description: 静态代理测试
 * @Date 2022/7/11 20:40
 */
public class StaticProxy {
    @Test
    public void staticProxy() {
        //创建房东对象
        FangDongService fangDongService = new FangDongServiceImpl();
        //创建代理对象
        FangDongProxyImpl proxy = new FangDongProxyImpl(fangDongService);
        //调用租房业务
        proxy.zuFang();
    }
}
